home *** CD-ROM | disk | FTP | other *** search
/ PC World 2008 September / PCWorld_2008-09_cd.bin / v cisle / sadanastroju / lightning-0.8-tb-win.xpi / chrome / calendar.jar / content / calendar / calendar-event-dialog.xul < prev    next >
Extensible Markup Language  |  2007-09-24  |  17KB  |  374 lines

  1. <?xml version="1.0"?>
  2. <!-- -*- Mode: xml; indent-tabs-mode: nil; -*- -->
  3. <!--
  4.    - ***** BEGIN LICENSE BLOCK *****
  5.    - Version: MPL 1.1/GPL 2.0/LGPL 2.1
  6.    -
  7.    - The contents of this file are subject to the Mozilla Public License Version
  8.    - 1.1 (the "License"); you may not use this file except in compliance with
  9.    - the License. You may obtain a copy of the License at
  10.    - http://www.mozilla.org/MPL/
  11.    -
  12.    - Software distributed under the License is distributed on an "AS IS" basis,
  13.    - WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
  14.    - for the specific language governing rights and limitations under the
  15.    - License.
  16.    -
  17.    - The Original Code is calendar views.
  18.    -
  19.    - The Initial Developer of the Original Code is Oracle Corporation
  20.    - Portions created by the Initial Developer are Copyright (C) 2005
  21.    - the Initial Developer. All Rights Reserved.
  22.    -
  23.    - Contributor(s):
  24.    -   Stuart Parmenter <stuart.parmenter@oracle.com>
  25.    -   Simon Paquet <bugzilla@babylonsounds.com>
  26.    -   Joey Minta <jminta@gmail.com>
  27.    -   C├⌐dric Corazza <cedric.corazza@wanadoo.fr>
  28.    -
  29.    - Alternatively, the contents of this file may be used under the terms of
  30.    - either the GNU General Public License Version 2 or later (the "GPL"), or
  31.    - the GNU Lesser General Public License Version 2.1 or later (the "LGPL"),
  32.    - in which case the provisions of the GPL or the LGPL are applicable instead
  33.    - of those above. If you wish to allow use of your version of this file only
  34.    - under the terms of either the GPL or the LGPL, and not to allow others to
  35.    - use your version of this file under the terms of the MPL, indicate your
  36.    - decision by deleting the provisions above and replace them with the notice
  37.    - and other provisions required by the GPL or the LGPL. If you do not delete
  38.    - the provisions above, a recipient may use your version of this file under
  39.    - the terms of any one of the MPL, the GPL or the LGPL.
  40.    -
  41.    - ***** END LICENSE BLOCK ***** -->
  42.  
  43. <?xml-stylesheet href="chrome://global/skin/global.css" type="text/css"?>
  44. <?xml-stylesheet href="chrome://calendar/content/calendar-event-dialog.css" type="text/css"?>
  45. <?xml-stylesheet href="chrome://calendar/content/datetimepickers/datetimepickers.css" ?>
  46.  
  47. <!DOCTYPE dialog
  48. [
  49.     <!ENTITY % calendar-event-dialogDTD SYSTEM "chrome://calendar/locale/calendar-event-dialog.dtd">
  50.     %calendar-event-dialogDTD;
  51. ]>     
  52.  
  53. <dialog
  54.   id="calendar-event-dialog"
  55.   title="&event.title.label;"
  56.   buttons="accept,cancel,disclosure"
  57.   ondialogaccept="return onAccept();"
  58.   ondialogcancel="return onCancel();"
  59.   ondialogdisclosure="toggleDetails();"
  60.   onload="onLoad()"
  61.   persist="screenX screenY width"
  62.   xmlns="http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul">
  63.  
  64.   <!-- Javascript includes -->
  65.   <script type="application/x-javascript" src="chrome://calendar/content/calendar-event-dialog.js"/>
  66.   <script type="application/x-javascript" src="chrome://calendar/content/calendar-dialog-utils.js"/>
  67.   <script type="application/x-javascript" src="chrome://calendar/content/calUtils.js"/>
  68.  
  69.   <!-- Used for the button to show/hide details -->
  70.   <script type="application/x-javascript">
  71.     var moreLabel = "&calendar.more.label; >>";      
  72.     var lessLabel = "<< &calendar.less.label;";
  73.   </script>
  74.  
  75.  
  76.   <vbox id="dialog-box" flex="1">
  77.     <label id="read-only-item" value="&newevent.readonly.item.warning;" 
  78.            class="warning-text-class" hidden="true"/>
  79.  
  80.     <grid flex="1">
  81.       <columns>
  82.         <column/>
  83.         <column flex="1"/>
  84.       </columns>
  85.  
  86.       <rows>
  87.         <row align="center">
  88.           <label value="&newevent.title.label;"
  89.                  accesskey="&newevent.title.accesskey;"
  90.                  control="item-title"/>
  91.           <hbox flex="1" align="center">
  92.             <textbox id="item-title" oninput="updateAccept();" flex="1"/>
  93.             <menulist id="component-type" crop="none"
  94.                       oncommand="updateComponentType(this.value)">
  95.               <menupopup id="component-menulist-menupopup">
  96.                 <menuitem label="&newevent.itemType.event.label;"
  97.                           value="event"/>
  98.                 <menuitem label="&newevent.itemType.todo.label;"
  99.                           value="todo"/>
  100.               </menupopup>
  101.             </menulist>
  102.           </hbox>
  103.         </row>
  104.  
  105.         <row align="center">
  106.           <label value="&newevent.location.label;"
  107.                  accesskey="&newevent.location.accesskey;"
  108.                  control="item-location"/>
  109.           <textbox id="item-location"/>
  110.         </row>
  111.  
  112.         <row align="center">
  113.           <hbox align="center">
  114.             <label value="&newevent.from.label;" class="event-only"
  115.                    accesskey="&newevent.from.accesskey;"
  116.                    control="event-starttime"/>
  117.             <label value="&newevent.date.label;" class="todo-only"
  118.                    accesskey="&newevent.date.accesskey;"
  119.                    control="todo-has-entrydate"/>
  120.           </hbox>
  121.           <hbox>
  122.             <datetimepicker id="event-starttime" onchange="onStartTimeChange();" 
  123.                             class="event-only"/>
  124.             <checkbox id="event-all-day" oncommand="updateAllDay();" 
  125.                       class="event-only" label="&newevent.alldayevent.label;"
  126.                       accesskey="&newevent.alldayevent.accesskey;"/>
  127.             <checkbox id="todo-has-entrydate" oncommand="updateEntryDate();" 
  128.                       class="todo-only checkbox-no-label"/>
  129.             <datetimepicker id="todo-entrydate" onchange="onStartTimeChange();" 
  130.                             class="todo-only"/>
  131.             <spacer flex="1"/>
  132.           </hbox>
  133.         </row>
  134.  
  135.         <row>
  136.           <hbox align="center">
  137.             <label value="&newevent.to.label;" class="event-only"
  138.                    accesskey="&newevent.to.accesskey;"
  139.                    control="event-endtime"/>
  140.             <label value="&newtodo.duedate.label;" class="todo-only"
  141.                    accesskey="&newtodo.duedate.accesskey;"
  142.                    control="todo-has-duedate"/>
  143.           </hbox>
  144.           <vbox>
  145.             <hbox align="center">
  146.               <datetimepicker id="event-endtime" onchange="onEndTimeChange();" class="event-only"/>
  147.               <checkbox id="todo-has-duedate" oncommand="updateDueDate();" class="todo-only checkbox-no-label"/>
  148.               <datetimepicker id="todo-duedate" onchange="onEndTimeChange();" class="todo-only"/>
  149.               <checkbox id="item-recurrence" oncommand="updateRecurrence();"
  150.                       label="&newevent.repeat2.label;"
  151.                       accesskey="&newevent.repeat2.accesskey;"/>
  152.               <button id="set-recurrence" label="&newevent.set.label;"
  153.                       oncommand="editRecurrence();"
  154.                       accesskey="&newevent.set.accesskey;"/>
  155.             </hbox>
  156.             <label id="end-time-warning" class="warning-text-class"
  157.                    value="&newevent.endtime.warning;"/>
  158.             <label id="task-repeat-warning" class="warning-text-class"
  159.                    value="&newtodo.repeatstart.warning;" hidden="true"/>
  160.           </vbox>
  161.         </row>
  162.  
  163.         <row>
  164.           <spacer height="5"/>
  165.         </row>
  166.  
  167.         <row align="center">
  168.           <label value="&newevent.server.label;"
  169.                  accesskey="&newevent.server.accesskey;"
  170.                  control="item-calendar"/>
  171.           <hbox align="center">
  172.             <menulist id="item-calendar" oncommand="updateAccept()"/>
  173.             <label id="read-only-cal"
  174.                    value="&newevent.readonly.cal.warning;"
  175.                    class="warning-text-class" hidden="true"/>
  176.             <spacer flex="1"/>
  177.             <hbox id="categories-box" align="center">
  178.                 <label value="&newtodo.categories.label;" class="label"
  179.                        accesskey="&newtodo.categories.accesskey;"
  180.                        control="item-categories"/>
  181.                 <menulist id="item-categories" oncommand="categorySelect(this.value)"/>
  182.             </hbox>
  183.           </hbox>
  184.         </row>
  185.  
  186.         <!-- Details -->
  187.  
  188.         <row details="true">
  189.           <spacer height="5"/>
  190.         </row>
  191.  
  192.         <!-- We work off of this row's collapsed state to determine whether or
  193.              not to show details when loading the dialog -->
  194.         <row id="description-row" details="true" collapsed="true" persist="collapsed" flex="1">
  195.           <label value="&newevent.description.label;"
  196.                  accesskey="&newevent.description.accesskey;"
  197.                  control="item-description"/>
  198.           <textbox id="item-description" multiline="true" rows="4" flex="1"/>
  199.         </row>
  200.  
  201.         <row details="true">
  202.           <label value="&newevent.attendees.label;"
  203.                  accesskey="&newevent.attendees.accesskey;"
  204.                  control="attendees-list"/>
  205.           <hbox flex="1">
  206.             <vbox flex="1">
  207.               <!-- XXX This should be changed to a richlistbox that actually
  208.                  -     works and doesn't need to be constrained by max-height.
  209.                 -->
  210.               <calendar-attendee-list id="attendees-list" flex="1"
  211.                                       style="max-height: 12em;"/>
  212.               <!-- This is only shown on Lightning, since Sunbird can't send
  213.                  - email yet. -->
  214.               <checkbox id="send-invitations-checkbox"
  215.                         collapsed="true"
  216.                         label="&newevent.attendees.sendEmail.label;"
  217.                         pack="start"/>
  218.             </vbox>
  219.             <spacer width="10"/>
  220.  
  221.             <grid>
  222.               <columns>
  223.                 <column/>
  224.                 <column/>
  225.               </columns>
  226.  
  227.               <rows>
  228.                 <row align="center">
  229.                   <label value="&newevent.privacy.label;"
  230.                          accesskey="&newevent.privacy.accesskey;"
  231.                          control="privacy-menulist"/>
  232.                   <menulist id="privacy-menulist" crop="none">
  233.                     <menupopup>
  234.                       <menuitem label="&newevent.public.label;" value="PUBLIC"/>
  235.                       <menuitem label="&newevent.private.label;" value="PRIVATE"/>
  236.                       <menuitem label="&newevent.confidential.label;" value="CONFIDENTIAL"/>
  237.                     </menupopup>
  238.                   </menulist>
  239.                 </row>
  240.  
  241.                 <row align="center">
  242.                   <label id="priority-label"
  243.                          value="&newtodo.priority.label;"
  244.                          accesskey="&newtodo.priority.accesskey;"
  245.                          control="priority-levels"/>
  246.                   <menulist id="priority-levels">
  247.                     <menupopup>
  248.                       <menuitem label="&priority.level.none;"   value="0"/>
  249.                       <menuitem label="&priority.level.low;"    value="9"/>
  250.                       <menuitem label="&priority.level.medium;" value="5"/>
  251.                       <menuitem label="&priority.level.high;"   value="1"/>
  252.                     </menupopup>
  253.                   </menulist>
  254.                 </row>
  255.  
  256.                 <row align="center">
  257.                   <label id="status-label" class="event-only"
  258.                          value="&newevent.status.label;"
  259.                          accesskey="&newevent.status.accesskey;"
  260.                          control="event-status"/>
  261.                   <menulist id="event-status" class="event-only">
  262.                     <menupopup>
  263.                       <menuitem label="&newevent.status.none.label;"
  264.                                 value="NONE"/>
  265.                       <menuitem label="&newevent.status.tentative.label;"
  266.                                 value="TENTATIVE"/>
  267.                       <menuitem label="&newevent.status.confirmed.label;"
  268.                                 value="CONFIRMED"/>
  269.                       <menuitem label="&newevent.status.cancelled.label;"
  270.                                 value="CANCELLED"/>
  271.                     </menupopup>
  272.                   </menulist>
  273.                 </row>
  274.  
  275.                 <row align="center">
  276.                   <label value="&newevent.alarm.label;"
  277.                          accesskey="&newevent.alarm.accesskey;"
  278.                          control="item-alarm"/>
  279.                   <hbox align="center">
  280.                     <menulist id="item-alarm" oncommand="updateAlarm()">
  281.                       <menupopup>
  282.                         <menuitem label="&newevent.none.label;" value="none" selected="true"/>
  283.                         <menuseparator/>
  284.                         <menuitem label="&newevent.15minutes.before.label;" length="15" unit="minutes" relation="START"/>
  285.                         <menuitem label="&newevent.30minutes.before.label;" length="30" unit="minutes" relation="START"/>
  286.                         <menuseparator/>
  287.                         <menuitem id="alarm-custom-menuitem" label="&newevent.custom.label;" value="custom"/>
  288.                       </menupopup>
  289.                     </menulist>
  290.                   </hbox>
  291.                 </row>
  292.  
  293.                 <row id="alarm-details">
  294.                   <spacer flex="1"/>
  295.                   <vbox>
  296.                     <hbox>
  297.                       <textbox id="alarm-length-field" size="1" oninput="validateIntegers(event);"/>
  298.                       <menulist id="alarm-length-units">
  299.                         <menupopup>
  300.                           <menuitem label="&alarm.units.minutes;" value="minutes" selected="true"/>
  301.                           <menuitem label="&alarm.units.hours;" value="hours"/>
  302.                           <menuitem label="&alarm.units.days;" value="days"/>
  303.                         </menupopup>
  304.                       </menulist>
  305.                       <menulist id="alarm-trigger-relation" oncommand="updateAccept()">
  306.                         <menupopup>
  307.                           <menuitem label="&newevent.before.label;" value="START" selected="true"/>
  308.                           <menuitem label="&newevent.after.label;" value="END"/>
  309.                         </menupopup>
  310.                       </menulist>
  311.                     </hbox>
  312.                   </vbox>
  313.                 </row>
  314.  
  315.                 <row id="alarm-warnings">
  316.                   <spacer flex="1"/>
  317.                   <vbox>
  318.                     <label id="alarm-start-warning" value="&alarm.start.warning;"
  319.                            class="warning-text-class"/>
  320.                     <label id="alarm-end-warning" value="&alarm.due.warning;"
  321.                            class="warning-text-class"/>
  322.                   </vbox>
  323.                 </row>
  324.               </rows>
  325.             </grid>
  326.           </hbox>
  327.         </row>
  328.  
  329.         <row details="true">
  330.           <spacer height="5"/>
  331.         </row>
  332.  
  333.         <row align="center" details="true">
  334.           <label value="&newevent.uri.label;"
  335.                  accesskey="&newevent.uri.accesskey;" control="item-url"/>
  336.           <hbox flex="1">
  337.             <textbox id="item-url" flex="1" oninput="updateURL(this.value)"/>
  338.             <button id="load-url-button" oncommand="loadURL()"
  339.                     label="&newevent.uri.visit.label;"
  340.                     accesskey="&newevent.uri.visit.accesskey;"/>
  341.           </hbox>
  342.         </row>
  343.  
  344.         <row align="center" class="todo-only" details="true">
  345.           <label id="todo-status-label" value="&newevent.status.label;" control="todo-status"/>
  346.           <hbox align="center">
  347.             <menulist id="todo-status" class="todo-only"
  348.                       oncommand="updateToDoStatus(this.value);">
  349.               <menupopup>
  350.                 <menuitem label="&newevent.status.none.label;"
  351.                           value="NONE"/>
  352.                 <menuitem label="&newevent.status.needsaction.label;"
  353.                           value="NEEDS-ACTION"/>
  354.                 <menuitem label="&newevent.status.inprogress.label;"
  355.                           value="IN-PROCESS"/>
  356.                 <menuitem label="&newevent.status.completed.label;"
  357.                           value="COMPLETED"/>
  358.                 <menuitem label="&newevent.status.cancelled.label;"
  359.                           value="CANCELLED"/>
  360.               </menupopup>
  361.             </menulist>
  362.             <datepicker id="completed-date-picker" class="todo-only"
  363.                         value="" disabled="true"/>
  364.             <textbox id="percent-complete-textbox" size="3" oninput="validateIntegers(event);"/>
  365.             <label id="percent-complete-label" class="todo-only"
  366.                    value="&newtodo.percentcomplete.label;"/>
  367.           </hbox>
  368.         </row>
  369.       </rows>
  370.     </grid>
  371.     <spacer height="10"/>
  372.   </vbox>
  373. </dialog>
  374.